<%@ taglib uri="/WEB-INF/struts-logic.tld" prefix="logic"%>
<%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean"%>
<%@ taglib uri="/WEB-INF/displaytag-11.tld" prefix="display"%>
<%@ taglib uri="/WEB-INF/struts-html.tld" prefix="html"%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>untitled</title>
<link href="../../css/jdeveloper.css" rel="stylesheet" media="screen" />
<link href="<%= request.getContextPath() + "/css/bloques.css" %>"
	rel="stylesheet" type="text/css">
<link href="<%= request.getContextPath() + "/css/table.css" %>"
	rel="stylesheet" type="text/css">
<script type="text/javascript">
      function retornar(path, option)
      {
        if(option == "1")
        {
          window.location=path+"/beneficiarios/Buscar.do";
        }else{
          document.frmconfirmar.action='<%=request.getContextPath()%>'+'/beneficiarios/VerGrupoFamiliar.do';
          document.frmconfirmar.submit();
        }
      }
    </script>
</head>
<body>
<div align="center">
	<table class="tablaGenericaWidth60">
		<logic:iterate id="bene" length="1" name="bene">
			<logic:iterate id="cabeza" length="1" name="cabezas">
				<html:form name="frmconfirmar"
					action="/beneficiarios/GuardarGrupoFamiliar.do" method="get"
					focus="codeParentesco"
					type="co.gov.medellin.ssti.sub.web.form.NuevoGrupoFamiliarForm">
					<tr>
						<td colspan="2" class="titulosenblanco">
							<DIV align="center">
								<STRONG>Confirmacion Grupo Familiar</STRONG>
							</DIV>
						</td>
					</tr>
					<tr>
						<td colspan="2">&nbsp;</td>
					</tr>
					<tr>
						<td width="25%" class="celdatabla" colspan="2">
							<DIV align="center">
								<STRONG>Beneficiario</STRONG>
							</DIV>
						</td>
					</tr>

					<tr>
						<td colspan="2">
							<DIV align="center">
								<bean:write name="bene" property="numeroDocumento" />
								-
								<bean:write name="bene" property="nombre1" />
								<bean:write name="bene" property="nombre2" />
								<bean:write name="bene" property="primerApellido" />
								<bean:write name="bene" property="segundoApellido" />
							</DIV>
						</td>
					</tr>


					<tr>
						<td colspan="2" class="celdatabla">
							<DIV align="center">
								<STRONG>Grupo Familiar</STRONG>
							</DIV>
						</td>
					</tr>
					<tr>
						<td width="40%">
							<DIV>Nombre Grupo Familiar:</DIV>
						</td>
						<td width="60%">
							<DIV class="form">
								<bean:write name="cabeza" property="grupoFamiliar" />
							</DIV>
						</td>
					</tr>
					<tr>
						<td width="40%">Cabeza Grupo Familiar</td>
						<td width="60%">
							<DIV class="form">
								<bean:write name="cabeza" property="numeroDocumento" />
								-
								<bean:write name="cabeza" property="nombre1" />
								<bean:write name="cabeza" property="nombre2" />
								<bean:write name="cabeza" property="primerApellido" />
								<bean:write name="cabeza" property="segundoApellido" />
							</DIV>
						</td>
					</tr>
					<tr>
						<td width="40%">Parentesco con respecto a la cabeza</td>
						<td width="60%">
							<%
            String strCode = (String)session.getAttribute("codeParentesco");
          %> <html:select property="codeParentesco" value="<%=strCode%>"
								styleClass="form">
								<html:option value="">Seleccione un rol</html:option>
								<html:options name="parentescos" labelName="code"
									labelProperty="descVflex" property="code"
									collection="parentescos" />
							</html:select>
						</td>
					</tr>
					<tr>
						<td colspan="2" class="celdatabla">&nbsp;</td>
					</tr>
					<tr>
						<td colspan="2">
							<DIV align="center">
								<input type="submit" value="Aceptar" /> <input type="hidden"
									name="origen" value="asignar" /> <input type="hidden"
									name="codeBeneficiario"
									value="<bean:write name="bene" property="code"/>" /> <input
									type="hidden" name="nombreGF"
									value="<bean:write name="cabeza" property="grupoFamiliar"/>" />
								<input type="hidden" name="codeGF"
									value="<bean:write name="cabeza" property="grupoFamiliarCode"/>" />
								<%
              String strOption = (String)session.getAttribute("Option");
              if(strOption != null && !strOption.equals(""))
              {
                
            %>

								<input type="button" value="Cancelar"
									onclick="retornar('<%=request.getContextPath()%>','<%=strOption%>')" />
								<%
              }else{
            %>

								<input type="button" value="Cancelar"
									onclick="retornar('<%=request.getContextPath()%>','1')" />
								<%
              }
            %>
							</DIV>
						</td>
					</tr>
				</html:form>
			</logic:iterate>
		</logic:iterate>
	</table>
	</div>
</body>
</html>
